/* 全局样式 */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
}

/* 侧边栏样式 */
.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
    background: linear-gradient(180deg, #343a40 0%, #212529 100%);
}

.sidebar-header {
    padding: 0.5rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link {
    font-weight: 500;
    color: rgba(255, 255, 255, .65);
    padding: 0.75rem 1rem;
    transition: all 0.3s;
}

.sidebar .nav-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.2);
    border-left: 4px solid #0d6efd;
}

.sidebar .nav-link i {
    margin-right: 0.5rem;
}

/* 主内容区样式 */
main {
    padding-top: 1.5rem;
}

/* 卡片样式 */
.card {
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: all 0.3s;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.card-header {
    border-top-left-radius: 0.5rem !important;
    border-top-right-radius: 0.5rem !important;
}

/* 数据展示卡片样式 */
#account-section .card-body {
    padding: 1.5rem;
}

#account-section .card-text {
    font-weight: 600;
    margin-top: 0.5rem;
}

/* 表格样式 */
.table {
    vertical-align: middle;
}

.table thead th {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* 正负值颜色 */
.positive {
    color: #198754;
}

.negative {
    color: #dc3545;
}

/* 响应式调整 */
@media (max-width: 767.98px) {
    .sidebar {
        position: static;
        height: auto;
        padding-top: 0;
    }
    
    main {
        margin-left: 0 !important;
    }
}

/* 动画效果 */
.fade-in {
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* 加载动画 */
.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* 设置部分样式 */
#settings-section .form-control {
    max-width: 400px;
}

/* 登录表单样式 */
#login-form {
    max-width: 800px;
    margin: 0 auto 2rem;
}

/* 美化滚动条 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}